<html lang="en">
    <head>
        <meta charset="utf-8">


	<!-- (en) Add your meta data here -->
	<!-- (de) Fuegen Sie hier ihre Meta-Daten ein -->
	<link href="<?php echo $basePath; ?>/admin_media/css/layout_3col_standard.css" rel="stylesheet" type="text/css"/>
	<!--[if lte IE 7]>
	<link href="<?php echo $basePath; ?>/admin_media/css/patches/patch_3col_standard.css" rel="stylesheet" type="text/css" />
	<![endif]-->

	<script type="text/javascript" src="<?php echo $basePath; ?>/library/jquery/jquery.js"></script>
	<link type="text/css" href="<?php echo $basePath; ?>/library/jquery-ui/themes/redmond/jquery-ui.css" rel="stylesheet" />	
	<script type="text/javascript" src="<?php echo $basePath; ?>/library/jquery-ui/ui/jquery-ui-all-in-one.js"></script>

<script type="text/javascript">

 $(document).ready(function() {
    
    $("a.edit").click(function(){
        var id = $(this).attr("id").replace("id_","");     
	window.opener.location.href = "<?php echo $basePath; ?>/<?php echo $adminAreaToken; ?>/keyword-edit/index/id_keyword/" + id;
        return false;
    });
    
 });

</script>


    </head>
    
<body>







<div id="main">

	<!-- begin: main content area #main -->
	<div class="page_margins">
	  <div class="page" id="main_content">

		  <!-- begin: #col3 static column -->
		  <div id="col3">

			<div id="col3_content" class="clearfix">
			  <!-- skiplink anchor: Content -->
				<!--#######################-->
				<!-- BEGIN: Module content -->
				<!--#######################-->
				<div id="module_content" role="main">
				    <a name="content"></a>


<div id="search_result">
    <h1 id="page_head"><?php echo ucfirst($type); ?> search result for: <?php echo $search; ?></h1>

    <?php if(count($result) > 0): ?>
 
          <?php  echo $this->paginationControl($paginator, 'Sliding', 
	    	'paginator-slide-keyword', 
	    	array('search'         => $search)); ?>
 
    <ul id="node-list">
    <?php foreach( $result as $val): ?>
        <li <?php if($val['id_status']==0): ?>
            class="status-trash" title="trash"
            <?php elseif($val['id_status']==100): ?>
            class="status-inactive" title="inactive"
            <?php elseif($val['id_status']==200): ?>
            class="status-active" title="active"
            <?php endif; ?>>
            <?php if($val['system_serial'] != NULL): ?>
            <h3><a href="#" class="edit" id="id_<?php echo $val['id_keyword']; ?>" title="edit in background window"><?php  echo $val['title']; ?></a></h3> 
            <?php else: ?>
            <h3><?php  echo $val['title']; ?></h3>                         
            <?php endif; ?>
                        
            <?php if(isset($val['lists']) && is_array($val['lists'])): ?>
            <?php foreach($val['lists'] as $list): ?>
            <p class="search_list_branch">Root/<?php  echo $list['branch']; ?></p>
            <?php endforeach; ?>
            <?php else: ?>
            <p class="search_list_branch">Root/<?php  echo $val['branch']; ?></p>
            <?php endif; ?>
            <?php if(!empty($val['attributes'])): ?>
            <?php if(count($val['attributes']) > 0): ?>
            <ul class="list_attributes_default">
            <?php foreach( $val['attributes'] as $attr): ?>
              <li><h4><?php echo $attr['info']['attribute_title']; ?>: <?php echo $escape->escapeHtml( $attr['value'] ); ?></h4></li>
            <?php endforeach; ?>
            </ul>
            <?php endif; ?>
            <?php endif; ?>
            </li>
    <?php endforeach; ?>
    </ul>
    
          <?php  echo $this->paginationControl($paginator, 'Sliding', 
	    	'paginator-slide-keyword', 
	    	array('search'         => $search)); ?>
    
    <?php endif; ?>  

</div>


				</div>
				<!--#####################-->
				<!-- END: Module content -->
				<!--#####################-->
			</div>

			<div id="ie_clearing">&nbsp;</div>
			<!-- End: IE Column Clearing -->
		  </div>
		  <!-- end: #col3 -->
	  </div>
	</div>
	
	<!-- end: #main -->

	<!-- begin: #footer -->
	<div id="footer">
		<div class="page_margins">
			<div class="page">
			  GeoContexter <br />Layout based on <a href="http://www.yaml.de/en">YAML</a>
			</div>
		</div>
	</div>
	<!-- end: #footer -->

</div>
</body>
</html>